package com.haixee.parkdemo.house_resource.feign;

import com.haixee.parkdemo.house_resource.entity.FieldRule;
import com.haixee.parkdemo.house_resource.entity.User;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

@FeignClient(value = "auth", path = "/")
public interface AuthService {

    @GetMapping("/user")
    User getUser(@RequestParam("uid") Integer uid);

    @GetMapping("/organize/under_tree")
    List<Integer> getUnderTree(@RequestParam("uid") Integer uid);

    @GetMapping("/field_rule")
    List<FieldRule> getFieldRule(@RequestParam("tableName") String tableName);
}
